import { GET_SHARE_LIST } from "../actionTyps";
import api from "../../api/share";
const userData = JSON.parse(localStorage.getItem("user"))
export const getShareList = () => {
    return (dispatch) => {
        api.getShareList({ user_id: userData.id }).then(res => {
            console.log(res);
            dispatch({
                type: GET_SHARE_LIST,
                payload: res.data.data
            })
        })
    }
}